"""
给定公司N名员工的工龄，要求按工龄增序输出每个工龄段有多少员工。
"""
n = eval(input())
p = list(map(int, input().split()))
s = set(p)
age = {key: 0 for key in p}
for i in p:
    age[i] += 1
for i in s:
    if age[i] != 0:
        print("{}:{}".format(i,age[i]))
